package week02;

import java.io.File;
import java.io.IOException;

public class test03 {

	public static void main(String[] args) {
		try{
			FileMethods fm=new FileMethods();
					
			File f=new File("D:\\javatest\\test.txt");
			fm.create(f);
			fm.delete(f);
		}
		catch(IOException e) {
			e.printStackTrace();
			}

		}
		public void create(File file)throws IOException {
			if (!file.exists()) {
				file.createNewFile();
			}
		}
		public void delete(File file)throws IOException {
			if(file.exists()) {
				file.delete();
			}}}

	


